﻿using Ninject.Modules;
using Soundteller.Bus.Model;
using Soundteller.Bus.Model.Interfaces;
using Soundteller.Bus.Repositories;
using Soundteller.Bus.Repositories.Interfaces;
using Soundteller.Bus.Services;
using Soundteller.Bus.Services.Interfaces;

namespace Soundteller.Bus
{
    public class BusModule : NinjectModule
    {
        public override void Load()
        {
            Bind<IMemoryContext>().To<MemoryContext>().InSingletonScope();

            Bind<IMessageHandlerRepository>().To<MessageHandlerRepository>().InSingletonScope();

            Bind<IPublisher>().To<Publisher>().InSingletonScope();
            Bind<ISubscriber>().To<Subscriber>().InSingletonScope();
        }
    }
}